<%@ page contentType="text/html;charset=UTF-8"%>
<%@ include file="../../views/common/taglibs.jsp"%>
  <div id="u30" class="ax_default shape">
                <div id="u30_div" class=""></div>
                <!-- Unnamed () -->
                <div id="u31" class="text" style="visibility: visible;">
                  <p><span>
                  	发布商品
        			</span></p>
                </div>
  </div>
  <div class="search">
	    <form id="publishItemFrm" name="publishItemFrm" action="${appServer}/back/item/publishItem.htm" method="post" onsubmit="return false;">
		    <table id="publishItemTbl">
				<c:if test="${msg!=null}">
        		<tr>
			    	<td class="tc">
	        			<h2>${msg}</h2>
	        		</td>
				</tr>
  				</c:if>
  				<c:if test="${errorMsg!=null}">
        		<tr>
			    	<td class="tc">
	        			<h2><font color="#FF0000">${errorMsg}</font></h2>
	        		</td>
				</tr>
  				</c:if>
				<tr>
			      	<td>
			      		供应商：&nbsp;&nbsp;
				      	<c:if test="${supplier!=null}">
				      		${supplier.memberName}
				      		<input type="hidden" name="memberName" value="${supplier.memberName}"/>
				      		<input type="hidden" name="userId" value="${supplier.memberId}"/>
			      		</c:if>
			      	</td>
			   </tr>
				<tr>
			      	<td>
			      		描述：&nbsp;&nbsp;
			      		<input type="text" name="itemDesc" style="width: 280px;"/>
			      	</td>
			   </tr>
			   <tr>
					<td>添加图片：<input type="file" id="imageUpload" name="file" style="display:-webkit-inline-box;width: 180px;"/>
					&nbsp;&nbsp;&nbsp;<input class="btn_add" value="上传图片" type="button" style="font-size: 9px;" onclick="updataItemImage();"/>
					<input id="picInput" type="hidden" name="pic" value=""/>
					<input id="descPicInput" type="hidden" name="descPic" value=""/>
					</td>
				</tr>
				<tr>
			      	<td id="itemImages">
			      		
			      	</td>
			   </tr>
			   <tr>
			      	<td>
			      		类目：&nbsp;&nbsp; 
			      		<select class="userinfo" id="categorySelect" name="categoryId" style="width: 190px;" onchange="selectCategory(this);">
			      			<option value="-1" selected ="selected">--请选择--</option>
			      			<c:if test="${categoryList!=null}">
					      		<c:forEach items="${categoryList}" var="categoryTemp" varStatus="status">
					      			<option value="${categoryTemp.id}">${categoryTemp.fullTitle}</option>
						      	</c:forEach>
					      	</c:if>
				      	</select>
			      	</td>
			   </tr>
			   <tr>
			      	<td>
			      		品牌：&nbsp;&nbsp;
			      	<select class="userinfo" id="brandSelect" name="brandId" style="width: 190px;" onchange="selectBrand(this);">
			      		<option value="-1" selected ="selected">--请先选择类目--</option>
			      	</select>
			      	</td>
			   </tr>
			   <tr>
			      	<td>
			      		适用人群：&nbsp;&nbsp;
			      		<select class="userinfo" id="featureSelect" name="feature" style="width: 90px;" onchange="selectFeature(this);">
							<option value=10>通用</option>
							<option value=0>女</option>
							<option value=1>男</option>
						</select>
			      	</td>
			   </tr>
				<tr>
			      	<td>
			      		建议零售价：&nbsp;&nbsp;
			      		<input type="text" name="referencePriceDisplay" style="width: 180px;"/>
			      	</td>
			   </tr>
				<tr>
			      	<td>
			      		结算价：&nbsp;&nbsp;
			      		<input type="text" name="priceDisplay" style="width: 180px;"/>
			      	</td>
			   </tr>
				<tr>
			      	<td>
			      		货币单位：&nbsp;&nbsp;
			      		<select class="userinfo" name="priceCurno" style="width: 90px;">
							<option value="CNY">人民币</option>
							<option value="HKD">港币</option>
							<option value="EUR">欧元</option>
							<option value="USD">美元</option>
							<option value="GBP">英镑</option>
							<option value="TWD">台币</option>
							<option value="JPY">日元</option>
							<option value="KRW">韩国元</option>
						</select>
			      	</td>
			   </tr>
			   <tr>
			      	<td>
			      		商品编码图：<input type="file" id="itemCodeImageUpload" name="file" style="width: 180px;"/>
			      	&nbsp;&nbsp;&nbsp;<input class="btn_add" value="上传图片" type="button" style="font-size: 9px;" onclick="updataItemCodeImage();"/>
					<input id="itemCodePicInput" type="hidden" name="itemCodePic" value=""/>
			      	</td>
			   </tr>
				<tr>
			      	<td id="itemCodeImage">
			      		
			      	</td>
			   </tr>
			    <tr>
			      	<td>
			      		商品编码：&nbsp;&nbsp;
			      		<input type="text" name="itemCode" style="width: 180px;"/>
			      	</td>
			    </tr>
				<tr>
			      	<td height="50">
			      		<hr/>
			      	</td>
			   </tr>
				<tr>
			      	<th style="text-align:left;">
			      		<div id="u33" class="text" style="visibility: visible;">
		                  <p><b>
		                  	标签管理：
		        			</b></p>
		                </div>
			      	</th>
			   </tr>
			    <tr>
			      	<td>
			      		标签：&nbsp;&nbsp;
				      		<input id="tagInput" type="text" style="width: 180px;"/>
				      		&nbsp;&nbsp;&nbsp;<input class="btn_add" value="添加" type="button" style="font-size: 9px;" onclick="addItemTag();"/>
				      		<input class="tagListInput" type="hidden" name="tagListString" value=""/>
			      	</td>
			    </tr>
			    <tr>
			      	<td>
			      		已添加标签：
			      	</td>
			   </tr>
				<tr>
			      	<td id="itemTags" style="text-align:left;">
			      		<span class='featureTag' style='position: relative;'>
							<button class='tagListButton' type='button' disabled='disabled'>通用</button>
							<input type='image' style='width:15px;height:auto;' src='../../images/main/Delete.png' onclick='deleteTag(this);'>&nbsp;&nbsp;
						</span>
			      	</td>
			   </tr>
				<tr>
			      	<td height="50">
			      		<hr/>
			      	</td>
			   </tr>
				<tr>
			      	<th style="text-align:left;">
			      		<div id="u33" class="text" style="visibility: visible;">
		                  <p><b>
		                  	库存：<input class="miniSkuListInput" type="hidden" name="miniSkuList" value=""/>
		        			</b></p>
		                </div>
			      	</th>
			   </tr>
			    <tr>
					<td class="tc"><input class="btn_add" name="" value="发布商品" type="button" onclick="publishItemSubmit();" /></td>
				</tr>
		    </table>
	    </form>
  </div>